<template>
    <div class="face-box">
      <div class="mooney-box flex-center">
        <div class="money">
          <div class="mb-5 font-size14 c-888 flex-center flex-x-center"><span class="mr-4">今日总收益</span><van-icon name="gold-coin" size="20"/></div>
          <div class="mb-4">
            <span class="font-size28 font-bold white mr-4">68.00</span><span class="font-size12 white">元</span>
          </div>
        </div>
      </div>
      <div class="main-box flex-around">
        <div class="icon-box flex-x-center" v-for="item,index in menuList" :key="index" @click="go(index)">
          <div class="image-box">
            <svg class="icon" aria-hidden="true" >
                  <use :xlink:href="'#'+item.icon"></use> 
            </svg>
          </div>
          <div class="info-box">{{ item.text }}</div>
        </div>
      </div>
    </div>

</template>
<script>
export default {
  data() {
    return {
        menuList:[{
          icon:'icon-shangjiadianpu',
          text:'商户信息'
        },{
          icon:'icon-liwu',
          text:'商品信息'
        },{
          icon:'icon-yuangongrenzheng',
          text:'员工信息'
        },{
          icon:'icon-huiyuanhuangguan',
          text:'用户会员'
        },{
          icon:'icon-dingdan',
          text:'订单明细'
        },{
          icon:'icon-jiangjin',
          text:'中奖信息'
        }]
    };
  },
  mounted() {
   
  },
  methods:{
    go(index){
      if(index == 0){
        this.$router.push({path:"/merchant"})
      }else if(index == 1){
        this.$router.push({path:"/product"})
      }else if(index == 4){
        this.$router.push({path:"/older"})
      }else if(index == 5){
        this.$router.push({path:"/winnInfo"})
      }else if(index == 3){
        this.$router.push({path:"/member"})
      }else if(index == 2){
        this.$router.push({path:"/employee"})
      }
    }
  }
}
</script>
<style scoped lang="scss">
  .mooney-box{
    width: 100%;
    height: 80px;
    background-color: #6995D2;
    .money{
      width: 100%;
      div{
        width: 100%;
      }
      .van-icon-gold-coin{
        color: rgb(233, 233, 233);
      }
    }
  }
  .main-box{
    width: 100%;
    height: 220px;
    margin-top: 10px;
    flex-wrap: wrap;
    align-content: space-around;
    border-bottom: 1px solid #f3f3f3;
    .icon-box{
      width: calc(33.33% - 10px);
      height: 100px;
      flex-wrap: wrap;
      .image-box{
        width: 70px;
        height: 70px;
        background-color: rgb(239, 253, 255);
        border-radius: 35px;
        display: flex;
        justify-content: center;
        align-items: center;
        .icon{
          width: 35px;
          height: 35px;
        }
      }
      .info-box{
        width: 100%;
        height: 30px;
        line-height: 30px;
      }
    }
    .icon-box:nth-child(3){
      .icon{
          width: 40px;
          height: 40px;
        }
    }
  }
</style>